Library with generic game algorithms